
package com.cmc.service.impl;

import java.util.List;

import com.cmc.service.impl.BaseManager;
import com.cmc.model.RightRule;
import com.cmc.dao.RightRuleDao;
import com.cmc.service.RightRuleManager;
/*
* @aegis.mapping
*/
public class RightRuleManagerImpl extends BaseManager implements RightRuleManager {
    private RightRuleDao dao;

    /**
     * Set the Dao for communication with the data layer.
     * @param dao
     */
    public void setRightRuleDao(RightRuleDao dao) {
        this.dao = dao;
    }

    /**
     * @see com.cmc.service.RightRuleManager#getRightRules(com.cmc.model.RightRule)
     */
    public List getRightRules(final RightRule rightRule) {
        return dao.getRightRules(rightRule);
    }

    /**
     * @see com.cmc.service.RightRuleManager#getRightRule(String id)
     */
    public RightRule getRightRule(final String id) {
        return dao.getRightRule(new Long(id));
    }

    /**
     * @see com.cmc.service.RightRuleManager#saveRightRule(RightRule rightRule)
     */
    public void saveRightRule(RightRule rightRule) {
        dao.saveRightRule(rightRule);
    }

    /**
     * @see com.cmc.service.RightRuleManager#removeRightRule(String id)
     */
    public void removeRightRule(final String id) {
        dao.removeRightRule(new Long(id));
    }
}
